import {
  ajax
} from "@/config/apiServer/axios-config.js";
import {
  URLS
} from "@/config/apiServer/urls.js";

// 车队长审批列表
export function getAuditList(params) {
  return ajax({
    type: 'post',
    url: URLS.ASSETS_COMMON,
    params: {
      uri: "/backend/fleet/list",
      method: "get",
      params: params
    }
  })
}

// 车队长审批
export function audit(params) {
  return ajax({
    type: 'post',
    url: URLS.ASSETS_COMMON,
    params: {
      uri: "/backend/fleet/approval",
      method: "get",
      params: params
    }
  })
}

// 添加车队长
export function addCarLeader(params) {
  return ajax({
    type: 'post',
    url: URLS.ASSETS_COMMON,
    params: {
      uri: "/backend/fleet/add-captain",
      method: "post",
      params: params
    }
  })
}
// 查询每日投放量
export function getDayReward() {
  return ajax({
    type: 'post',
    url: URLS.ASSETS_COMMON,
    params: {
      uri: "/backend/config/fleet-config",
      method: "get"
    }
  })
}
// 修改每日投放量
export function editDayReward(fleetRewardBaseNum) {
  return ajax({
    type: 'post',
    url: URLS.ASSETS_COMMON,
    params: {
      uri: "/backend/config/edit-fleet",
      method: "post",
      params: {
        fleetRewardBaseNum
      }
    }
  })
}